class NewSingRank {
  int jSCSSDATE;
  String kgDomain;
  String src;
  Null fr;
  String ver;
  List<Data> data;
  List<Banner> banner;
  String sTpl;

  NewSingRank(
      {this.jSCSSDATE,
        this.kgDomain,
        this.src,
        this.fr,
        this.ver,
        this.data,
        this.banner,
        this.sTpl});

  NewSingRank.fromJson(Map<String, dynamic> json) {
    jSCSSDATE = json['JS_CSS_DATE'];
    kgDomain = json['kg_domain'];
    src = json['src'];
    fr = json['fr'];
    ver = json['ver'];
    if (json['data'] != null) {
      data = new List<Data>();
      json['data'].forEach((v) {
        data.add(new Data.fromJson(v));
      });
    }
    if (json['banner'] != null) {
      banner = new List<Banner>();
      json['banner'].forEach((v) {
        banner.add(new Banner.fromJson(v));
      });
    }
    sTpl = json['__Tpl'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['JS_CSS_DATE'] = this.jSCSSDATE;
    data['kg_domain'] = this.kgDomain;
    data['src'] = this.src;
    data['fr'] = this.fr;
    data['ver'] = this.ver;
    if (this.data != null) {
      data['data'] = this.data.map((v) => v.toJson()).toList();
    }
    if (this.banner != null) {
      data['banner'] = this.banner.map((v) => v.toJson()).toList();
    }
    data['__Tpl'] = this.sTpl;
    return data;
  }
}

class Data {
  int payType320;
  int m4afilesize;
  int priceSq;
  int first;
  int filesize;
  int bitrate;
  TransParam transParam;
  int price;
  int inlist;
  int oldCpy;
  int pkgPriceSq;
  int payType;
  String topicUrl;
  String rpType;
  int pkgPrice;
  String recommendReason;
  String filename;
  int price320;
  String extname;
  String hash;
  int audioId;
  int privilege;
  String topicUrl320;
  String addtime;
  int pkgPrice320;
  int sqfilesize;
  int failProcess320;
  int duration;
  int feetype;
  int i320filesize;
  int rpPublish;
  int hasAccompany;
  String topicUrlSq;
  String remark;
  int isfirst;
  String sqhash;
  int i320privilege;
  String s320hash;
  int failProcess;
  String albumId;
  int payTypeSq;
  String mvhash;
  int sqprivilege;
  int albumAudioId;
  int failProcessSq;

  Data(
      {this.payType320,
        this.m4afilesize,
        this.priceSq,
        this.first,
        this.filesize,
        this.bitrate,
        this.transParam,
        this.price,
        this.inlist,
        this.oldCpy,
        this.pkgPriceSq,
        this.payType,
        this.topicUrl,
        this.rpType,
        this.pkgPrice,
        this.recommendReason,
        this.filename,
        this.price320,
        this.extname,
        this.hash,
        this.audioId,
        this.privilege,
        this.topicUrl320,
        this.addtime,
        this.pkgPrice320,
        this.sqfilesize,
        this.failProcess320,
        this.duration,
        this.feetype,
        this.i320filesize,
        this.rpPublish,
        this.hasAccompany,
        this.topicUrlSq,
        this.remark,
        this.isfirst,
        this.sqhash,
        this.i320privilege,
        this.s320hash,
        this.failProcess,
        this.albumId,
        this.payTypeSq,
        this.mvhash,
        this.sqprivilege,
        this.albumAudioId,
        this.failProcessSq});

  Data.fromJson(Map<String, dynamic> json) {
    payType320 = json['pay_type_320'];
    m4afilesize = json['m4afilesize'];
    priceSq = json['price_sq'];
    first = json['first'];
    filesize = json['filesize'];
    bitrate = json['bitrate'];
    transParam = json['trans_param'] != null
        ? new TransParam.fromJson(json['trans_param'])
        : null;
    price = json['price'];
    inlist = json['inlist'];
    oldCpy = json['old_cpy'];
    pkgPriceSq = json['pkg_price_sq'];
    payType = json['pay_type'];
    topicUrl = json['topic_url'];
    rpType = json['rp_type'];
    pkgPrice = json['pkg_price'];
    recommendReason = json['recommend_reason'];
    filename = json['filename'];
    price320 = json['price_320'];
    extname = json['extname'];
    hash = json['hash'];
    audioId = json['audio_id'];
    privilege = json['privilege'];
    topicUrl320 = json['topic_url_320'];
    addtime = json['addtime'];
    pkgPrice320 = json['pkg_price_320'];
    sqfilesize = json['sqfilesize'];
    failProcess320 = json['fail_process_320'];
    duration = json['duration'];
    feetype = json['feetype'];
    i320filesize = json['320filesize'];
    rpPublish = json['rp_publish'];
    hasAccompany = json['has_accompany'];
    topicUrlSq = json['topic_url_sq'];
    remark = json['remark'];
    isfirst = json['isfirst'];
    sqhash = json['sqhash'];
    i320privilege = json['320privilege'];
    s320hash = json['320hash'];
    failProcess = json['fail_process'];
    albumId = json['album_id'];
    payTypeSq = json['pay_type_sq'];
    mvhash = json['mvhash'];
    sqprivilege = json['sqprivilege'];
    albumAudioId = json['album_audio_id'];
    failProcessSq = json['fail_process_sq'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['pay_type_320'] = this.payType320;
    data['m4afilesize'] = this.m4afilesize;
    data['price_sq'] = this.priceSq;
    data['first'] = this.first;
    data['filesize'] = this.filesize;
    data['bitrate'] = this.bitrate;
    if (this.transParam != null) {
      data['trans_param'] = this.transParam.toJson();
    }
    data['price'] = this.price;
    data['inlist'] = this.inlist;
    data['old_cpy'] = this.oldCpy;
    data['pkg_price_sq'] = this.pkgPriceSq;
    data['pay_type'] = this.payType;
    data['topic_url'] = this.topicUrl;
    data['rp_type'] = this.rpType;
    data['pkg_price'] = this.pkgPrice;
    data['recommend_reason'] = this.recommendReason;
    data['filename'] = this.filename;
    data['price_320'] = this.price320;
    data['extname'] = this.extname;
    data['hash'] = this.hash;
    data['audio_id'] = this.audioId;
    data['privilege'] = this.privilege;
    data['topic_url_320'] = this.topicUrl320;
    data['addtime'] = this.addtime;
    data['pkg_price_320'] = this.pkgPrice320;
    data['sqfilesize'] = this.sqfilesize;
    data['fail_process_320'] = this.failProcess320;
    data['duration'] = this.duration;
    data['feetype'] = this.feetype;
    data['320filesize'] = this.i320filesize;
    data['rp_publish'] = this.rpPublish;
    data['has_accompany'] = this.hasAccompany;
    data['topic_url_sq'] = this.topicUrlSq;
    data['remark'] = this.remark;
    data['isfirst'] = this.isfirst;
    data['sqhash'] = this.sqhash;
    data['320privilege'] = this.i320privilege;
    data['320hash'] = this.s320hash;
    data['fail_process'] = this.failProcess;
    data['album_id'] = this.albumId;
    data['pay_type_sq'] = this.payTypeSq;
    data['mvhash'] = this.mvhash;
    data['sqprivilege'] = this.sqprivilege;
    data['album_audio_id'] = this.albumAudioId;
    data['fail_process_sq'] = this.failProcessSq;
    return data;
  }
}

class TransParam {
  int cid;
  int payBlockTpl;
  int musicpackAdvance;
  int displayRate;
  int display;

  TransParam(
      {this.cid,
        this.payBlockTpl,
        this.musicpackAdvance,
        this.displayRate,
        this.display});

  TransParam.fromJson(Map<String, dynamic> json) {
    cid = json['cid'];
    payBlockTpl = json['pay_block_tpl'];
    musicpackAdvance = json['musicpack_advance'];
    displayRate = json['display_rate'];
    display = json['display'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['cid'] = this.cid;
    data['pay_block_tpl'] = this.payBlockTpl;
    data['musicpack_advance'] = this.musicpackAdvance;
    data['display_rate'] = this.displayRate;
    data['display'] = this.display;
    return data;
  }
}

class Banner {
  String imgurl;
  String title;
  int id;
  int type;
  int online;
  Extra extra;

  Banner(
      {this.imgurl, this.title, this.id, this.type, this.online, this.extra});

  Banner.fromJson(Map<String, dynamic> json) {
    imgurl = json['imgurl'];
    title = json['title'];
    id = json['id'];
    type = json['type'];
    online = json['online'];
    extra = json['extra'] != null ? new Extra.fromJson(json['extra']) : null;
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['imgurl'] = this.imgurl;
    data['title'] = this.title;
    data['id'] = this.id;
    data['type'] = this.type;
    data['online'] = this.online;
    if (this.extra != null) {
      data['extra'] = this.extra.toJson();
    }
    return data;
  }
}

class Extra {
  String tourl;
  TransParam transParam;
  int playCount;
  String specialname;
  String publishtime;
  String singername;
  String intro;
  int type;
  int songcount;
  String imgurl;
  int collectcount;
  int suid;
  int percount;
  String globalSpecialid;
  int specialid;
  int slid;

  Extra(
      {this.tourl,
        this.transParam,
        this.playCount,
        this.specialname,
        this.publishtime,
        this.singername,
        this.intro,
        this.type,
        this.songcount,
        this.imgurl,
        this.collectcount,
        this.suid,
        this.percount,
        this.globalSpecialid,
        this.specialid,
        this.slid});

  Extra.fromJson(Map<String, dynamic> json) {
    tourl = json['tourl'];
    transParam = json['trans_param'] != null
        ? new TransParam.fromJson(json['trans_param'])
        : null;
    playCount = json['play_count'];
    specialname = json['specialname'];
    publishtime = json['publishtime'];
    singername = json['singername'];
    intro = json['intro'];
    type = json['type'];
    songcount = json['songcount'];
    imgurl = json['imgurl'];
    collectcount = json['collectcount'];
    suid = json['suid'];
    percount = json['percount'];
    globalSpecialid = json['global_specialid'];
    specialid = json['specialid'];
    slid = json['slid'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['tourl'] = this.tourl;
    if (this.transParam != null) {
      data['trans_param'] = this.transParam.toJson();
    }
    data['play_count'] = this.playCount;
    data['specialname'] = this.specialname;
    data['publishtime'] = this.publishtime;
    data['singername'] = this.singername;
    data['intro'] = this.intro;
    data['type'] = this.type;
    data['songcount'] = this.songcount;
    data['imgurl'] = this.imgurl;
    data['collectcount'] = this.collectcount;
    data['suid'] = this.suid;
    data['percount'] = this.percount;
    data['global_specialid'] = this.globalSpecialid;
    data['specialid'] = this.specialid;
    data['slid'] = this.slid;
    return data;
  }
}
